# Copyright 2019 Google LLC
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
#     http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.

# NOTE: This file is auto generated by the elixir code generator program.
# Do not edit this file manually.

defmodule GoogleApi.VMwareEngine.V1.Model.PrivateCloud do
  @moduledoc """
  Represents a private cloud resource. Private clouds of type `STANDARD` and `TIME_LIMITED` are zonal resources, `STRETCHED` private clouds are regional.

  ## Attributes

  *   `createTime` (*type:* `DateTime.t`, *default:* `nil`) - Output only. Creation time of this resource.
  *   `deleteTime` (*type:* `DateTime.t`, *default:* `nil`) - Output only. Time when the resource was scheduled for deletion.
  *   `description` (*type:* `String.t`, *default:* `nil`) - User-provided description for this private cloud.
  *   `expireTime` (*type:* `DateTime.t`, *default:* `nil`) - Output only. Time when the resource will be irreversibly deleted.
  *   `hcx` (*type:* `GoogleApi.VMwareEngine.V1.Model.Hcx.t`, *default:* `nil`) - Output only. HCX appliance.
  *   `managementCluster` (*type:* `GoogleApi.VMwareEngine.V1.Model.ManagementCluster.t`, *default:* `nil`) - Required. Input only. The management cluster for this private cloud. This field is required during creation of the private cloud to provide details for the default cluster. The following fields can't be changed after private cloud creation: `ManagementCluster.clusterId`, `ManagementCluster.nodeTypeId`.
  *   `name` (*type:* `String.t`, *default:* `nil`) - Output only. Identifier. The resource name of this private cloud. Resource names are schemeless URIs that follow the conventions in https://cloud.google.com/apis/design/resource_names. For example: `projects/my-project/locations/us-central1-a/privateClouds/my-cloud`
  *   `networkConfig` (*type:* `GoogleApi.VMwareEngine.V1.Model.NetworkConfig.t`, *default:* `nil`) - Required. Network configuration of the private cloud.
  *   `nsx` (*type:* `GoogleApi.VMwareEngine.V1.Model.Nsx.t`, *default:* `nil`) - Output only. NSX appliance.
  *   `state` (*type:* `String.t`, *default:* `nil`) - Output only. State of the resource. New values may be added to this enum when appropriate.
  *   `type` (*type:* `String.t`, *default:* `nil`) - Optional. Type of the private cloud. Defaults to STANDARD.
  *   `uid` (*type:* `String.t`, *default:* `nil`) - Output only. System-generated unique identifier for the resource.
  *   `updateTime` (*type:* `DateTime.t`, *default:* `nil`) - Output only. Last update time of this resource.
  *   `vcenter` (*type:* `GoogleApi.VMwareEngine.V1.Model.Vcenter.t`, *default:* `nil`) - Output only. Vcenter appliance.
  """

  use GoogleApi.Gax.ModelBase

  @type t :: %__MODULE__{
          :createTime => DateTime.t() | nil,
          :deleteTime => DateTime.t() | nil,
          :description => String.t() | nil,
          :expireTime => DateTime.t() | nil,
          :hcx => GoogleApi.VMwareEngine.V1.Model.Hcx.t() | nil,
          :managementCluster => GoogleApi.VMwareEngine.V1.Model.ManagementCluster.t() | nil,
          :name => String.t() | nil,
          :networkConfig => GoogleApi.VMwareEngine.V1.Model.NetworkConfig.t() | nil,
          :nsx => GoogleApi.VMwareEngine.V1.Model.Nsx.t() | nil,
          :state => String.t() | nil,
          :type => String.t() | nil,
          :uid => String.t() | nil,
          :updateTime => DateTime.t() | nil,
          :vcenter => GoogleApi.VMwareEngine.V1.Model.Vcenter.t() | nil
        }

  field(:createTime, as: DateTime)
  field(:deleteTime, as: DateTime)
  field(:description)
  field(:expireTime, as: DateTime)
  field(:hcx, as: GoogleApi.VMwareEngine.V1.Model.Hcx)
  field(:managementCluster, as: GoogleApi.VMwareEngine.V1.Model.ManagementCluster)
  field(:name)
  field(:networkConfig, as: GoogleApi.VMwareEngine.V1.Model.NetworkConfig)
  field(:nsx, as: GoogleApi.VMwareEngine.V1.Model.Nsx)
  field(:state)
  field(:type)
  field(:uid)
  field(:updateTime, as: DateTime)
  field(:vcenter, as: GoogleApi.VMwareEngine.V1.Model.Vcenter)
end

defimpl Poison.Decoder, for: GoogleApi.VMwareEngine.V1.Model.PrivateCloud do
  def decode(value, options) do
    GoogleApi.VMwareEngine.V1.Model.PrivateCloud.decode(value, options)
  end
end

defimpl Poison.Encoder, for: GoogleApi.VMwareEngine.V1.Model.PrivateCloud do
  def encode(value, options) do
    GoogleApi.Gax.ModelBase.encode(value, options)
  end
end
